-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(LongTextTooltip): Added LongTextTooltip component. #41
Conversation
692f2ba
to
99fba75
Compare
@@ -0,0 +1,3 @@ | |||
export { default } from './LongTextTooltip'; | |||
export { default as LongTextTooltip } from './LongTextTooltip'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should not provide a named export for the component, just a default one
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
all set.
...ternfly-docs/content/extensions/component-groups/examples/LongTextTooltip/LongTextTooltip.md
Outdated
Show resolved
Hide resolved
…roups/examples/LongTextTooltip/LongTextTooltip.md Co-authored-by: Filip Hlavac <[email protected]>
🎉 This PR is included in version 1.2.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
--- | ||
section: extensions | ||
subsection: Component groups | ||
id: Long text tooltip | ||
source: react | ||
propComponents: ['LongTextTooltip'] | ||
--- | ||
|
||
import LongTextTooltip from "@patternfly/react-component-groups/dist/dynamic/LongTextTooltip"; | ||
|
||
The **long text tooltip** component is a tooltip that can be used to display long text to users. It uses the `Tooltip` component to display the truncated text passed in as `content`. It uses `maxLength` prop to control the size of the content, and the `Tooltip` component to display the rest of the content. | ||
|
||
## Examples | ||
|
||
### LongTextTooltip component | ||
|
||
To provide users with long text, a basic long text tooltip should contain an appropriate and informative `content` and `maxLength`. Additionally you can pass in a `tooltipPosition` to control the position of the tooltip, and `tooltipMaxWidth` to control the tool tip width. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
---
section: extensions
subsection: Component groups
id: Long-text tooltip
source: react
propComponents: ['LongTextTooltip']
---
import LongTextTooltip from "@patternfly/react-component-groups/dist/dynamic/LongTextTooltip";
The **long-text tooltip** component enables you to display long text to users via a tooltip. It builds off of the [tooltip component](/components/tooltip) to truncate UI text in an element and display the truncated text in a tooltip.
## Examples
### Basic long-text tooltip
To show users the full value of truncated content , a basic long-text tooltip should contain appropriate and informative `content` and specify the `maxLength` of the UI text (after which, truncation will occur).
Additionally you can pass in a `tooltipPosition` to control the position of the tooltip, and `tooltipMaxWidth` to control the tool tip width.
🎉 This PR is included in version 5.0.0-prerelease.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Added LongTextTooltip to component groups repo.